#pragma once
#include "shapebuilder.h"

#define LINE_TWO_CUID _T("647F8760-73F4-464A-8EC0-A08F64A3A407")

class TFunction_Logbook;
class PRMAPI CLineInfo : public CShapeInfo
{
public:
	CLineInfo();
	~CLineInfo();
	virtual void Reset();

	virtual void GetParams(CVarList& varList, UINT nID);
	virtual void SetParams(const CVarList& varList, UINT nID);

	virtual bool GetFromLabel(TDF_Label& label);
	virtual void AddToLabel(TDF_Label& label);
	virtual bool ModifyLabel(TDF_Label& label, TFunction_Logbook& log);

	static bool IsModified(TDF_Label& label, const TFunction_Logbook& log);
//-----------------------------------
	gp_Pnt	ptStart;
	gp_Pnt	ptEnd;
//----------------------------------
	enum PARAM_INDEX_LINE
	{
		IDX_START = 0,

		START_POINT	= 1,
			START_X = START_POINT,
			START_Y,
			START_Z,
		END_POINT,
			END_X = END_POINT,
			END_Y,
			END_Z,

		IDX_END
	};
};

//////////////////////////////////////////////////////////////////////////

class PRMAPI CLineBuilder : public CShapeBuilder
{
public:
	CLineBuilder();
	~CLineBuilder();

	bool Build(const CString& szCmdParam, TopoDS_Shape& shape);
	bool Build(CLineInfo* pShapeInfo, TopoDS_Shape& shape);
};